package com.sc.nft.entity.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.sc.nft.enums.PrizeDrawActivityTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

@Data
public class ActivityBasicsDTO {
    @ApiModelProperty(value = "活动名称")
    @NotNull(message = "活动名称不能为空")
    @Length(min = 1, max = 10, message = "最大长度为10个汉字")
    private String nameActivity;

    @ApiModelProperty(value = "道具名称")
//    @NotNull(message = "道具名称不能为空")
    private String propName;

    @ApiModelProperty(value = "开始时间")
    @NotNull(message = "开始时间不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date startTime;

    @ApiModelProperty(value = "结束时间")
    @NotNull(message = "结束时间不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date endTime;

    @ApiModelProperty(value = "排序,由大到小")
    @NotNull(message = "排序不能为空")
    private Integer sort;

    @ApiModelProperty(value = "封面图片")
    @NotNull(message = "封面图片不能为空")
    private String coverImg;

    @ApiModelProperty(value = "规则图片")
    @NotNull(message = "规则图片不能为空")
    private String ruleImg;

    @ApiModelProperty(value = "道具id")
//    @NotNull(message = "道具不能为空")
    private Long propId;

    @ApiModelProperty(value = "类型 1:竞猜活动 2:瓜分活动 3:连续签到活动 4：累计签到活动")
    @NotNull(message = "类型不能为空")
    private PrizeDrawActivityTypeEnum type;

    @ApiModelProperty(value = "是否关联藏品")
    private Boolean isRelease;

    @ApiModelProperty(value = "关联藏品")
    private List<Long> releaseCollections;

    @ApiModelProperty(value = "是否开启注册时间限制")
    private Boolean isRegisterTime;

    @ApiModelProperty(value = "注册开始时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date registerBeginTime;

    @ApiModelProperty(value = "注册结束时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date registerEndTime;

}
